#ifndef __VCAPTURE_H__
#define __VCAPTURE_H__
#include "video.h"
#include "handle.h"
#include "gdi.h"
#include "game.h"
#include "window.h"
#include "camera.h"
#include "dxgi_.h"
#include "videocontext.h"

class VCapture :
	public VCaptureHandle
{
private:
	IVideo* m_pVideoCrap;
	IVideo* m_pCamera;
	void initVideoCrap(crapType);
	void crapHandle();
	void cameraHandle();
	bool supportDxgi();
	void init(crapType type);
public:
	VCapture(crapType type = DESKTOP);
	virtual ~VCapture();

	void SetRenderParam(int w, int h, HWND hwnd);
	void SetCameraParam(int w, int h, HWND hwnd);
	void StartCrap();
	void Stop();
};
#endif
